<html>
<head>
</head>
<body>
<script>
function RTELoaded(editor){
editor.setHTML("<div></div>"+"<font color=red>red</font>")
}
</script>
<IFRAME SRC="rte.htm" id='richedit' style='position: absolute; left: 0px; top: 0px; height=100%; width=100%'></IFRAME>


<input type=button value=" 查看代码 " onclick="htmlcode.innerText=richedit.getHTML()">

<div id=htmlcode></div>
</body>
</html>